<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
</head>
<body>
<!--注意height属性-->
<div id="root" style="height:100%;"></div>
</body>

<!-- <script src="http://10.0.0.72:3000/webpack-dev-server.js"></script>
<script src="http://10.0.0.72:3000/bundle.js"></script> -->

<script type="application/javascript">
    var protocol="http://";
    var hostname=window.location.hostname;

    function isDebug() {
        return true;
    }

    var port=3000;

    if(hostname.startsWith("docker"))
    {
        port=3001;
    }

    var baseSrc=protocol+hostname+":"+port;


    function require(src) {
        var hm = document.createElement("script");
        hm.src = baseSrc+src;
        var s = document.getElementsByTagName("script")[0];
        document.body.appendChild(hm);
    }

    if(isDebug())
    {
        require("/webpack-dev-server.js");
        require("/bundle.js");
    } else
    {
        require("/bundle.min.js");
    }



</script>

<!--

<script type="application/javascript">
    var protocol="http://";
    var hostname=window.location.hostname;
    var port=3000;

    var baseSrc=protocol+hostname+":"+port;

    function isDebug() {

        var url = window.location.hash;

        return (url.indexOf("debug")>0);
    }

    function require(src) {
        var hm = document.createElement("script");
        if(src.indexOf(".min.") >= 0)
        {
            hm.src = src;
        }
        else
        {
            hm.src = baseSrc+src;
        }
        //var s = document.getElementsByTagName("script")[0];
        document.body.appendChild(hm);
    }

    if(isDebug())
    {
        require("/webpack-dev-server.js");
        require("/bundle.js");
    } else
    {
        require("/static/bundle.min.js");
    }
</script>
-->
</html>
